VERSION 5.00
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCTL.OCX"
Object = "{BDC217C8-ED16-11CD-956C-0000C04E4C0A}#1.1#0"; "TABCTL32.OCX"
Object = "{CDE57A40-8B86-11D0-B3C6-00A0C90AEA82}#1.0#0"; "MSDATGRD.OCX"
Object = "{B3FB64BF-91F9-11D7-A482-0008A14158BC}#2.22#0"; "ITGControls.ocx"
Begin VB.Form frmMFGBillOfMaterial 
   BorderStyle     =   1  'Fixed Single
   Caption         =   "Bill of Materials"
   ClientHeight    =   8850
   ClientLeft      =   45
   ClientTop       =   330
   ClientWidth     =   9150
   BeginProperty Font 
      Name            =   "Tahoma"
      Size            =   8.25
      Charset         =   0
      Weight          =   400
      Underline       =   0   'False
      Italic          =   0   'False
      Strikethrough   =   0   'False
   EndProperty
   Icon            =   "frmMFGBillOfMaterial.frx":0000
   KeyPreview      =   -1  'True
   LinkTopic       =   "Form1"
   LockControls    =   -1  'True
   MaxButton       =   0   'False
   MDIChild        =   -1  'True
   ScaleHeight     =   8850
   ScaleWidth      =   9150
   Begin VB.Frame Frame3 
      Height          =   975
      Left            =   90
      TabIndex        =   3
      Top             =   60
      Width           =   8955
      Begin VB.Label lblDetails 
         Caption         =   "Product Division, Balance"
         ForeColor       =   &H00000000&
         Height          =   255
         Left            =   300
         TabIndex        =   4
         Top             =   600
         Width           =   7065
      End
      Begin VB.Label lblHeader 
         Caption         =   "Item No. - Description"
         BeginProperty Font 
            Name            =   "Tahoma"
            Size            =   12
            Charset         =   0
            Weight          =   700
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H00000000&
         Height          =   375
         Left            =   300
         TabIndex        =   5
         Top             =   240
         Width           =   7050
      End
   End
   Begin MSComctlLib.StatusBar sbRS 
      Align           =   2  'Align Bottom
      Height          =   255
      Left            =   0
      TabIndex        =   6
      Top             =   8595
      Width           =   9150
      _ExtentX        =   16140
      _ExtentY        =   450
      _Version        =   393216
      BeginProperty Panels {8E3867A5-8586-11D1-B16A-00C0F0283628} 
         NumPanels       =   2
         BeginProperty Panel1 {8E3867AB-8586-11D1-B16A-00C0F0283628} 
            Object.Width           =   3528
            MinWidth        =   3528
         EndProperty
         BeginProperty Panel2 {8E3867AB-8586-11D1-B16A-00C0F0283628} 
         EndProperty
      EndProperty
   End
   Begin TabDlg.SSTab SSTab2 
      Height          =   3405
      Left            =   75
      TabIndex        =   7
      Top             =   1125
      Width           =   9015
      _ExtentX        =   15901
      _ExtentY        =   6006
      _Version        =   393216
      Tabs            =   2
      TabsPerRow      =   2
      TabHeight       =   520
      TabMaxWidth     =   3528
      TabCaption(0)   =   "Main"
      TabPicture(0)   =   "frmMFGBillOfMaterial.frx":0CCA
      Tab(0).ControlEnabled=   -1  'True
      Tab(0).Control(0)=   "Frame1"
      Tab(0).Control(0).Enabled=   0   'False
      Tab(0).ControlCount=   1
      TabCaption(1)   =   "List"
      TabPicture(1)   =   "frmMFGBillOfMaterial.frx":0CE6
      Tab(1).ControlEnabled=   0   'False
      Tab(1).Control(0)=   "dtgList"
      Tab(1).ControlCount=   1
      Begin VB.Frame Frame1 
         Height          =   2940
         Left            =   120
         TabIndex        =   8
         Top             =   360
         Width           =   8760
         Begin VB.Frame Frame5 
            Height          =   675
            Left            =   195
            TabIndex        =   16
            Top             =   2115
            Width           =   5175
            Begin VB.OptionButton Option3 
               Caption         =   "Serialized"
               Height          =   255
               Left            =   3555
               TabIndex        =   19
               Top             =   270
               Width           =   1515
            End
            Begin VB.OptionButton Option2 
               Caption         =   "Lotted"
               Height          =   255
               Left            =   2025
               TabIndex        =   18
               Top             =   270
               Width           =   1515
            End
            Begin VB.OptionButton Option1 
               Caption         =   "Kitted"
               Height          =   255
               Left            =   465
               TabIndex        =   17
               Top             =   270
               Width           =   1515
            End
         End
         Begin VB.Frame Frame4 
            Height          =   1470
            Left            =   5565
            TabIndex        =   12
            Top             =   1320
            Width           =   2910
            Begin ITGControls.ITGTextBox txtSRP 
               Height          =   285
               Left            =   165
               TabIndex        =   13
               Top             =   255
               Width           =   2520
               _ExtentX        =   4233
               _ExtentY        =   503
               SendKeysTab     =   -1  'True
               BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
                  Name            =   "Tahoma"
                  Size            =   8.25
                  Charset         =   0
                  Weight          =   400
                  Underline       =   0   'False
                  Italic          =   0   'False
                  Strikethrough   =   0   'False
               EndProperty
               Text            =   "0"
               AllCaps         =   -1  'True
               DataType        =   1
               Mandatory       =   -1  'True
               DecimalPlace    =   2
               Label           =   "Component Cost"
               BeginProperty LabelFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
                  Name            =   "Tahoma"
                  Size            =   8.25
                  Charset         =   0
                  Weight          =   400
                  Underline       =   0   'False
                  Italic          =   0   'False
                  Strikethrough   =   0   'False
               EndProperty
               LabelWidth      =   1450
               TextBoxWidth    =   1010
            End
            Begin ITGControls.ITGTextBox txtSSRP 
               Height          =   285
               Left            =   165
               TabIndex        =   14
               Top             =   630
               Width           =   2520
               _ExtentX        =   4233
               _ExtentY        =   503
               SendKeysTab     =   -1  'True
               BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
                  Name            =   "Tahoma"
                  Size            =   8.25
                  Charset         =   0
                  Weight          =   400
                  Underline       =   0   'False
                  Italic          =   0   'False
                  Strikethrough   =   0   'False
               EndProperty
               Text            =   "0"
               AllCaps         =   -1  'True
               DataType        =   1
               Mandatory       =   -1  'True
               DecimalPlace    =   2
               Label           =   "Labor Cost"
               BeginProperty LabelFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
                  Name            =   "Tahoma"
                  Size            =   8.25
                  Charset         =   0
                  Weight          =   400
                  Underline       =   0   'False
                  Italic          =   0   'False
                  Strikethrough   =   0   'False
               EndProperty
               LabelWidth      =   1450
               TextBoxWidth    =   1010
            End
            Begin ITGControls.ITGTextBox txtSCost 
               Height          =   285
               Left            =   165
               TabIndex        =   15
               Top             =   1005
               Width           =   2520
               _ExtentX        =   4233
               _ExtentY        =   503
               SendKeysTab     =   -1  'True
               BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
                  Name            =   "Tahoma"
                  Size            =   8.25
                  Charset         =   0
                  Weight          =   400
                  Underline       =   0   'False
                  Italic          =   0   'False
                  Strikethrough   =   0   'False
               EndProperty
               Text            =   "0"
               AllCaps         =   -1  'True
               DataType        =   1
               Mandatory       =   -1  'True
               DecimalPlace    =   2
               Label           =   "Total Cost"
               BeginProperty LabelFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
                  Name            =   "Tahoma"
                  Size            =   8.25
                  Charset         =   0
                  Weight          =   400
                  Underline       =   0   'False
                  Italic          =   0   'False
                  Strikethrough   =   0   'False
               EndProperty
               LabelWidth      =   1450
               TextBoxWidth    =   1010
            End
         End
         Begin VB.CommandButton cmdPickWH 
            Height          =   300
            Left            =   3150
            Picture         =   "frmMFGBillOfMaterial.frx":0D02
            Style           =   1  'Graphical
            TabIndex        =   2
            Top             =   240
            Width           =   315
         End
         Begin ITGControls.ITGTextBox txtItemNo 
            Height          =   285
            Left            =   240
            TabIndex        =   0
            Top             =   240
            Width           =   2850
            _ExtentX        =   4815
            _ExtentY        =   503
            SendKeysTab     =   -1  'True
            BackColor       =   14745599
            BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
               Name            =   "Tahoma"
               Size            =   8.25
               Charset         =   0
               Weight          =   400
               Underline       =   0   'False
               Italic          =   0   'False
               Strikethrough   =   0   'False
            EndProperty
            AllCaps         =   -1  'True
            Mandatory       =   -1  'True
            Label           =   "Item No."
            BeginProperty LabelFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
               Name            =   "Tahoma"
               Size            =   8.25
               Charset         =   0
               Weight          =   400
               Underline       =   0   'False
               Italic          =   0   'False
               Strikethrough   =   0   'False
            EndProperty
            LabelWidth      =   1320
            TextBoxWidth    =   1470
         End
         Begin ITGControls.ITGTextBox txtDesc 
            Height          =   285
            Left            =   240
            TabIndex        =   1
            Top             =   600
            Width           =   8295
            _ExtentX        =   14420
            _ExtentY        =   503
            SendKeysTab     =   -1  'True
            BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
               Name            =   "Tahoma"
               Size            =   8.25
               Charset         =   0
               Weight          =   400
               Underline       =   0   'False
               Italic          =   0   'False
               Strikethrough   =   0   'False
            EndProperty
            AllCaps         =   -1  'True
            Mandatory       =   -1  'True
            Label           =   "Remarks"
            BeginProperty LabelFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
               Name            =   "Tahoma"
               Size            =   8.25
               Charset         =   0
               Weight          =   400
               Underline       =   0   'False
               Italic          =   0   'False
               Strikethrough   =   0   'False
            EndProperty
            LabelWidth      =   1320
            TextBoxWidth    =   6915
         End
         Begin ITGControls.ITGTextBox txtPDDesc 
            Height          =   285
            Left            =   3540
            TabIndex        =   11
            Top             =   240
            Width           =   4995
            _ExtentX        =   8705
            _ExtentY        =   503
            SendKeysTab     =   -1  'True
            BackColor       =   14737632
            BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
               Name            =   "Tahoma"
               Size            =   8.25
               Charset         =   0
               Weight          =   400
               Underline       =   0   'False
               Italic          =   0   'False
               Strikethrough   =   0   'False
            EndProperty
            AllCaps         =   -1  'True
            Label           =   "ITGtext"
            BeginProperty LabelFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
               Name            =   "Tahoma"
               Size            =   8.25
               Charset         =   0
               Weight          =   400
               Underline       =   0   'False
               Italic          =   0   'False
               Strikethrough   =   0   'False
            EndProperty
            LabelWidth      =   0
            TextBoxWidth    =   4935
            Enabled         =   0   'False
         End
         Begin ITGControls.ITGTextBox ITGTextBox1 
            Height          =   285
            Left            =   240
            TabIndex        =   24
            Top             =   1380
            Width           =   2385
            _ExtentX        =   3995
            _ExtentY        =   503
            SendKeysTab     =   -1  'True
            BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
               Name            =   "Tahoma"
               Size            =   8.25
               Charset         =   0
               Weight          =   400
               Underline       =   0   'False
               Italic          =   0   'False
               Strikethrough   =   0   'False
            EndProperty
            Text            =   "0"
            AllCaps         =   -1  'True
            DataType        =   1
            Mandatory       =   -1  'True
            DecimalPlace    =   2
            Label           =   "Quantity"
            BeginProperty LabelFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
               Name            =   "Tahoma"
               Size            =   8.25
               Charset         =   0
               Weight          =   400
               Underline       =   0   'False
               Italic          =   0   'False
               Strikethrough   =   0   'False
            EndProperty
            LabelWidth      =   1320
            TextBoxWidth    =   1005
         End
         Begin ITGControls.ITGTextBox ITGTextBox2 
            Height          =   285
            Left            =   240
            TabIndex        =   25
            Top             =   1740
            Width           =   2385
            _ExtentX        =   3995
            _ExtentY        =   503
            SendKeysTab     =   -1  'True
            BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
               Name            =   "Tahoma"
               Size            =   8.25
               Charset         =   0
               Weight          =   400
               Underline       =   0   'False
               Italic          =   0   'False
               Strikethrough   =   0   'False
            EndProperty
            Text            =   "0"
            AllCaps         =   -1  'True
            DataType        =   1
            Mandatory       =   -1  'True
            DecimalPlace    =   2
            Label           =   "Cost per Unit"
            BeginProperty LabelFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
               Name            =   "Tahoma"
               Size            =   8.25
               Charset         =   0
               Weight          =   400
               Underline       =   0   'False
               Italic          =   0   'False
               Strikethrough   =   0   'False
            EndProperty
            LabelWidth      =   1320
            TextBoxWidth    =   1005
         End
         Begin VB.Label Label4 
            AutoSize        =   -1  'True
            BackStyle       =   0  'Transparent
            Caption         =   "Information"
            BeginProperty Font 
               Name            =   "Tahoma"
               Size            =   8.25
               Charset         =   0
               Weight          =   700
               Underline       =   0   'False
               Italic          =   0   'False
               Strikethrough   =   0   'False
            EndProperty
            ForeColor       =   &H00000000&
            Height          =   195
            Left            =   120
            TabIndex        =   9
            Top             =   1020
            Width           =   1020
         End
         Begin VB.Line Line1 
            BorderColor     =   &H00000000&
            X1              =   1185
            X2              =   8655
            Y1              =   1140
            Y2              =   1140
         End
      End
      Begin MSDataGridLib.DataGrid dtgList 
         Height          =   2850
         Left            =   -74880
         TabIndex        =   10
         Top             =   420
         Width           =   8760
         _ExtentX        =   15452
         _ExtentY        =   5027
         _Version        =   393216
         AllowUpdate     =   0   'False
         AllowArrows     =   -1  'True
         Appearance      =   0
         HeadLines       =   1
         RowHeight       =   15
         TabAction       =   2
         FormatLocked    =   -1  'True
         BeginProperty HeadFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
            Name            =   "Tahoma"
            Size            =   8.25
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
            Name            =   "Tahoma"
            Size            =   8.25
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ColumnCount     =   5
         BeginProperty Column00 
            DataField       =   "cSupplyNo"
            Caption         =   "Supply ID"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   0
               Format          =   "0"
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   0
            EndProperty
         EndProperty
         BeginProperty Column01 
            DataField       =   "cDesc"
            Caption         =   "Description"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   0
               Format          =   ""
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   0
            EndProperty
         EndProperty
         BeginProperty Column02 
            DataField       =   "cPartNo"
            Caption         =   "Part Number"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   0
               Format          =   ""
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   0
            EndProperty
         EndProperty
         BeginProperty Column03 
            DataField       =   "cType"
            Caption         =   "Type"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   0
               Format          =   ""
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   0
            EndProperty
         EndProperty
         BeginProperty Column04 
            DataField       =   "cCosting"
            Caption         =   "Costing"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   0
               Format          =   ""
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   0
            EndProperty
         EndProperty
         SplitCount      =   1
         BeginProperty Split0 
            AllowRowSizing  =   0   'False
            BeginProperty Column00 
               ColumnAllowSizing=   -1  'True
               Locked          =   -1  'True
               ColumnWidth     =   1695.118
            EndProperty
            BeginProperty Column01 
               Locked          =   -1  'True
               ColumnWidth     =   3360.189
            EndProperty
            BeginProperty Column02 
               Locked          =   -1  'True
            EndProperty
            BeginProperty Column03 
               Locked          =   -1  'True
            EndProperty
            BeginProperty Column04 
               Locked          =   -1  'True
            EndProperty
         EndProperty
      End
   End
   Begin TabDlg.SSTab SSTab1 
      Height          =   3960
      Left            =   60
      TabIndex        =   20
      Top             =   4575
      Width           =   9030
      _ExtentX        =   15928
      _ExtentY        =   6985
      _Version        =   393216
      Tabs            =   5
      TabsPerRow      =   5
      TabHeight       =   520
      TabCaption(0)   =   "Components"
      TabPicture(0)   =   "frmMFGBillOfMaterial.frx":0E4C
      Tab(0).ControlEnabled=   -1  'True
      Tab(0).Control(0)=   "DataGrid1"
      Tab(0).Control(0).Enabled=   0   'False
      Tab(0).ControlCount=   1
      TabCaption(1)   =   "Equipment"
      TabPicture(1)   =   "frmMFGBillOfMaterial.frx":0E68
      Tab(1).ControlEnabled=   0   'False
      Tab(1).Control(0)=   "DataGrid2"
      Tab(1).Control(0).Enabled=   0   'False
      Tab(1).ControlCount=   1
      TabCaption(2)   =   "Labor"
      TabPicture(2)   =   "frmMFGBillOfMaterial.frx":0E84
      Tab(2).ControlEnabled=   0   'False
      Tab(2).Control(0)=   "DataGrid3"
      Tab(2).Control(0).Enabled=   0   'False
      Tab(2).ControlCount=   1
      TabCaption(3)   =   "Instructions"
      TabPicture(3)   =   "frmMFGBillOfMaterial.frx":0EA0
      Tab(3).ControlEnabled=   0   'False
      Tab(3).ControlCount=   0
      TabCaption(4)   =   "Usage"
      TabPicture(4)   =   "frmMFGBillOfMaterial.frx":0EBC
      Tab(4).ControlEnabled=   0   'False
      Tab(4).ControlCount=   0
      Begin MSDataGridLib.DataGrid DataGrid1 
         Height          =   3360
         Left            =   135
         TabIndex        =   21
         Top             =   450
         Width           =   8745
         _ExtentX        =   15425
         _ExtentY        =   5927
         _Version        =   393216
         AllowArrows     =   -1  'True
         HeadLines       =   1
         RowHeight       =   15
         TabAction       =   2
         FormatLocked    =   -1  'True
         BeginProperty HeadFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
            Name            =   "Tahoma"
            Size            =   8.25
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
            Name            =   "Tahoma"
            Size            =   8.25
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ColumnCount     =   6
         BeginProperty Column00 
            DataField       =   "cType"
            Caption         =   "Type"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   1
               Format          =   "#,##0.00"
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   1
            EndProperty
         EndProperty
         BeginProperty Column01 
            DataField       =   "cItemNo"
            Caption         =   "Item No."
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   0
               Format          =   ""
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   0
            EndProperty
         EndProperty
         BeginProperty Column02 
            DataField       =   "cDesc"
            Caption         =   "Description"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   0
               Format          =   "0.00"
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   0
            EndProperty
         EndProperty
         BeginProperty Column03 
            DataField       =   "nQty"
            Caption         =   "Quantity"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   1
               Format          =   "#,##0.00"
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   1
            EndProperty
         EndProperty
         BeginProperty Column04 
            DataField       =   "nCost"
            Caption         =   "Cost"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   1
               Format          =   "#,##0.00"
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   1
            EndProperty
         EndProperty
         BeginProperty Column05 
            DataField       =   "nAmount"
            Caption         =   "Amount"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   0
               Format          =   ""
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   0
            EndProperty
         EndProperty
         SplitCount      =   1
         BeginProperty Split0 
            BeginProperty Column00 
               Button          =   -1  'True
               ColumnWidth     =   959.811
            EndProperty
            BeginProperty Column01 
               Locked          =   -1  'True
               ColumnWidth     =   1454.74
            EndProperty
            BeginProperty Column02 
               ColumnWidth     =   2940.095
            EndProperty
            BeginProperty Column03 
               Alignment       =   1
               Locked          =   -1  'True
               ColumnWidth     =   989.858
            EndProperty
            BeginProperty Column04 
               Alignment       =   1
               Locked          =   -1  'True
               ColumnWidth     =   1019.906
            EndProperty
            BeginProperty Column05 
               ColumnWidth     =   1065.26
            EndProperty
         EndProperty
      End
      Begin MSDataGridLib.DataGrid DataGrid2 
         Height          =   3360
         Left            =   -74865
         TabIndex        =   22
         Top             =   450
         Width           =   8745
         _ExtentX        =   15425
         _ExtentY        =   5927
         _Version        =   393216
         AllowArrows     =   -1  'True
         HeadLines       =   1
         RowHeight       =   15
         TabAction       =   2
         FormatLocked    =   -1  'True
         BeginProperty HeadFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
            Name            =   "Tahoma"
            Size            =   8.25
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
            Name            =   "Tahoma"
            Size            =   8.25
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ColumnCount     =   6
         BeginProperty Column00 
            DataField       =   "cNumber"
            Caption         =   "No."
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   1
               Format          =   "#,##0.00"
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   1
            EndProperty
         EndProperty
         BeginProperty Column01 
            DataField       =   "cEquipment"
            Caption         =   "Equipment"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   0
               Format          =   ""
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   0
            EndProperty
         EndProperty
         BeginProperty Column02 
            DataField       =   "nQty"
            Caption         =   "Minutes"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   1
               Format          =   "#,##0.00"
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   1
            EndProperty
         EndProperty
         BeginProperty Column03 
            DataField       =   "cUnit"
            Caption         =   "Unit"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   0
               Format          =   ""
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   0
            EndProperty
         EndProperty
         BeginProperty Column04 
            DataField       =   "nCost"
            Caption         =   "Cost"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   1
               Format          =   "#,##0.00"
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   1
            EndProperty
         EndProperty
         BeginProperty Column05 
            DataField       =   "nAmount"
            Caption         =   "Amount"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   0
               Format          =   ""
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   0
            EndProperty
         EndProperty
         SplitCount      =   1
         BeginProperty Split0 
            BeginProperty Column00 
               Button          =   -1  'True
               ColumnWidth     =   959.811
            EndProperty
            BeginProperty Column01 
               Locked          =   -1  'True
               ColumnWidth     =   3300.095
            EndProperty
            BeginProperty Column02 
               Alignment       =   1
               Locked          =   -1  'True
               ColumnWidth     =   989.858
            EndProperty
            BeginProperty Column03 
               ColumnWidth     =   959.811
            EndProperty
            BeginProperty Column04 
               Alignment       =   1
               Locked          =   -1  'True
               ColumnWidth     =   1019.906
            EndProperty
            BeginProperty Column05 
               ColumnWidth     =   1184.882
            EndProperty
         EndProperty
      End
      Begin MSDataGridLib.DataGrid DataGrid3 
         Height          =   3360
         Left            =   -74865
         TabIndex        =   23
         Top             =   450
         Width           =   8745
         _ExtentX        =   15425
         _ExtentY        =   5927
         _Version        =   393216
         AllowArrows     =   -1  'True
         HeadLines       =   1
         RowHeight       =   15
         TabAction       =   2
         FormatLocked    =   -1  'True
         BeginProperty HeadFont {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
            Name            =   "Tahoma"
            Size            =   8.25
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
            Name            =   "Tahoma"
            Size            =   8.25
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ColumnCount     =   6
         BeginProperty Column00 
            DataField       =   "cNumber"
            Caption         =   "No."
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   1
               Format          =   "#,##0.00"
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   1
            EndProperty
         EndProperty
         BeginProperty Column01 
            DataField       =   "cPersonnel"
            Caption         =   "Personnel"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   0
               Format          =   ""
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   0
            EndProperty
         EndProperty
         BeginProperty Column02 
            DataField       =   "nQty"
            Caption         =   "Quantity"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   1
               Format          =   "#,##0.00"
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   1
            EndProperty
         EndProperty
         BeginProperty Column03 
            DataField       =   "cUnit"
            Caption         =   "Unit"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   0
               Format          =   ""
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   0
            EndProperty
         EndProperty
         BeginProperty Column04 
            DataField       =   "nCost"
            Caption         =   "Cost"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   1
               Format          =   "#,##0.00"
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   1
            EndProperty
         EndProperty
         BeginProperty Column05 
            DataField       =   "nAmount"
            Caption         =   "Amount"
            BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
               Type            =   0
               Format          =   ""
               HaveTrueFalseNull=   0
               FirstDayOfWeek  =   0
               FirstWeekOfYear =   0
               LCID            =   1033
               SubFormatType   =   0
            EndProperty
         EndProperty
         SplitCount      =   1
         BeginProperty Split0 
            BeginProperty Column00 
               Button          =   -1  'True
               ColumnWidth     =   959.811
            EndProperty
            BeginProperty Column01 
               Locked          =   -1  'True
               ColumnWidth     =   3300.095
            EndProperty
            BeginProperty Column02 
               Alignment       =   1
               Locked          =   -1  'True
               ColumnWidth     =   989.858
            EndProperty
            BeginProperty Column03 
               ColumnWidth     =   959.811
            EndProperty
            BeginProperty Column04 
               Alignment       =   1
               Locked          =   -1  'True
               ColumnWidth     =   1019.906
            EndProperty
            BeginProperty Column05 
               ColumnWidth     =   1184.882
            EndProperty
         EndProperty
      End
   End
End
Attribute VB_Name = "frmMFGBillOfMaterial"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
''logicglass inc. 2003.07.17
'
'Option Explicit
'
''Object variables
'
'
'
'
'
''Recordset variables
'Private WithEvents rsHeader As ADODB.Recordset
'Private rsC As ADODB.Recordset
'Private rsDummy As ADODB.Recordset
'Private rsDummyC As ADODB.Recordset
'
'Private rsHistory As ADODB.Recordset
'
''ADO Connection variables
'
'Private connHeader As ADODB.Connection
'Private connC As ADODB.Connection
'
''Form mode enumeration
'Public Enum eSupplyMode
'    Normal
'    AddNewEdit
'    Find
'End Enum
'Private Mode As eSupplyMode
'
''Other declaration
'Public dtgName As String
'Public sBit As String
'Private vBM As Variant 'Recordset bookmark variable
'
''Security Acess Level variables
'Public lACNew As Boolean
'Public lACEdit As Boolean
'Public lACDelete As Boolean
'Public lACPost As Boolean
'Public lACCancel As Boolean
'Public lACPrint As Boolean
'
'Private Sub cboType_Click()
'    txtType = Trim(cboType)
'End Sub
'
'Private Sub cboType_KeyPress(KeyAscii As Integer)
'    SendKeysTab KeyAscii
'End Sub
'
'Private Sub cmdHistory_Click()
''Dim cmdHist As ADODB.Command
''
''    If Not IsDate(dtbFrom.Text) Then
''        MsgBox "Please input date parameter.", vbInformation, "ComUnion"
''        dtbFrom.SetFocus
''        Exit Sub
''    ElseIf Not IsDate(dtbTo.Text) Then
''        MsgBox "Please input date parameter.", vbInformation, "ComUnion"
''        dtbTo.SetFocus
''        Exit Sub
''    End If
''
''    Set rsHistory = Nothing
''    Set rsHistory = New Recordset
''    Set dtgHistory.DataSource = Nothing
''    dtgHistory.Refresh
''
''    Set cmdHist = New ADODB.Command
''
''    With cmdHist
''        .ActiveConnection = cn
''        .CommandTimeout = 1000
''        .CommandText = "rsp_Inventory_Product_Movement_History"
''        .CommandType = adCmdStoredProc
''
''        .Parameters("@cFrom") = Trim(txtItemNo)
''        .Parameters("@cTo") = Trim(txtItemNo)
''        .Parameters("@cCompID") = COID
''
''        .Parameters("@cCompName") = ""
''        .Parameters("@cAddress1") = ""
''        .Parameters("@cAddress2") = ""
''        .Parameters("@cReportTitle") = ""
''        .Parameters("@cCriteria1") = ""
''        .Parameters("@cCriteria") = ""
''
''        .Parameters("@dDateFrom") = Trim(dtbFrom.Text)
''        .Parameters("@dDateTo") = Trim(dtbTo.Text)
''    End With
''
''    Set rsHistory = cmdHist.Execute()
''    Set cmdHist = Nothing
''
''    rsHistory.Filter = "cItemNo = '" & Trim(txtItemNo) & "'"
''    Set dtgHistory.DataSource = rsHistory
'
'End Sub
'
'Private Sub cmdPickDept_Click()
'    If lPickListActive Then Exit Sub
'    frmITGPickList.mType = Department
'    frmITGPickList.Show vbModal
'    txtDept = frmITGPickList.mCode
'    If Trim(txtDept) <> "" Then SendKeys "{Tab}"
'End Sub
'
'Private Sub dtgC_AfterColUpdate(ByVal ColIndex As Integer)
'    If Mode <> AddNewEdit Then Exit Sub
'    Select Case ColIndex
'        Case 0
'            If GetValueFrTable("cSupplyNo", "Supply", "cSupplyNo = '" & Trim(dtgC.Columns(0).Value) & "'") <> "" Then
'                GetItemValues rsC, dtgC, dtgC.Columns(0).Value
'            End If
'    End Select
'End Sub
'
'Private Sub dtgC_ButtonClick(ByVal ColIndex As Integer)
'    If Mode <> AddNewEdit Then Exit Sub
'    Select Case ColIndex
'        Case 0
'            If lPickListActive Then Exit Sub
'            sFilterString = Trim(dtgC.Columns(0).Text)
'            frmITGPickList.mType = Product
'            frmITGPickList.Show vbModal
'            dtgC.Columns(0).Value = Trim(frmITGPickList.mCode) & ""
'            If (Trim(frmITGPickList.mName) & "") <> "" Then
'                GetItemValues rsC, dtgC, dtgC.Columns(0).Value
'            End If
'            dtgC.Col = 3
'            dtgC.Columns(3).Value = 0
'    End Select
'End Sub
'
''Set the datagrid as active control
'Private Sub dtgC_Click()
'    If Mode = AddNewEdit Then dtgName = dtgC.Name
'End Sub
'
'Private Sub dtgC_Error(ByVal DataError As Integer, Response As Integer)
'    Response = 0
'End Sub
'
'Private Sub dtgC_GotFocus()
'    dtgName = dtgC.Name
'End Sub
'
'Private Sub dtgC_KeyDown(KeyCode As Integer, Shift As Integer)
'    If Mode <> AddNewEdit Then Exit Sub
'    If (Shift = vbCtrlMask And KeyCode = 45) Then
'        TBNewLine
'    ElseIf (Shift = vbCtrlMask And KeyCode = 46) Then
'        TBDeleteLine
'    ElseIf (Shift = vbCtrlMask And KeyCode = 83) Then
'        TBSave
'    End If
'End Sub
'
'Private Sub dtgC_KeyPress(KeyAscii As Integer)
'    If Mode <> AddNewEdit Then Exit Sub
'    If rsC.RecordCount = 0 Then Exit Sub
'
'    If KeyAscii = 39 Then KeyAscii = 0 'Apostrophe {'}
'
'    If KeyAscii = 13 Then
'        Select Case dtgC.Col
'            Case 0
'                If GetValueFrTable("cSupplyNo", "Supply", "cSupplyNo = '" & Trim(dtgC.Columns(0).Text) & "'") = "" Then
'                    dtgC_ButtonClick (0) 'use button click
'                End If
'            Case Else
'                SendKeys "{Tab}"
'        End Select
'    Else
'        KeyAscii = Asc(UCase(Chr(KeyAscii)))
'    End If
'End Sub
'
''Right click menu popup
'Private Sub dtgC_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
'    If Mode <> AddNewEdit Then Exit Sub
'    If Button = 2 Then
'        dtgName = dtgC.Name
'        PopupMenu ITGLedgerMain.mnuDetail
'    End If
'End Sub
'
'Private Sub dtgHistory_HeadClick(ByVal ColIndex As Integer)
'On Error Resume Next
'    SortGrid dtgHistory, ColIndex, rsHistory
'End Sub
'
'Private Sub dtgHistory_KeyDown(KeyCode As Integer, Shift As Integer)
'    If Mode <> AddNewEdit Then Exit Sub
'    If (Shift = vbCtrlMask And KeyCode = 83) Then
'        TBSave
'    End If
'End Sub
'
'Private Sub dtgList_HeadClick(ByVal ColIndex As Integer)
'    SortGrid dtgList, ColIndex, rsHeader
'End Sub
'
'Private Sub cmdPickWH_Click()
'    If lPickListActive Then Exit Sub
'    frmITGPickList.mType = Warehouse
'    frmITGPickList.Show vbModal
'    rsHeader!cWH = frmITGPickList.mCode
'    If Trim(txtWH) <> "" Then SendKeys "{Tab}"
'End Sub
'
''Set Your Object
'Private Sub Form_Load()
'
'    AcessBit Me, GetValueFrTable("AccessLevel", "SEC_ACCESSLEVEL", "RoleID = '" & SecUserRole & "' AND [Module] = 'MF25'")
'
'    Set rsHeader = New ADODB.Recordset
'    Set rsC = New ADODB.Recordset
'
'
'    Call LoadComboValues(cboType, "cParamName", "PARAMETER_SYSTEM", "WHERE cType = 'SUPPTYPE'", "nOrder")
'
'    Set FrmName = Me
'    FormLocking True
'    BitEnabled ITGLedgerMain, Me, ITGLedgerMain.tbrMain, lACNew, , , , , , , , , True, , , True
'    BitVisible ITGLedgerMain.tbrMain, True
'    ITGLedgerMain.tbrMain.Buttons("btnFind").ButtonMenus("btnFindP").Enabled = True
'
'    Mode = Find
'    txtItemNo.Locked = False
'End Sub
'
''Activate your Toolbar Mode
'Private Sub Form_Activate()
'    TBBitReload
'End Sub
'
''Release your Object
'Private Sub Form_Unload(Cancel As Integer)
'On Error Resume Next
'
'    If Mode = AddNewEdit Then
'        MsgBox "Unable to close. You are in Add/New/Edit mode." & vbCr & _
'            " Must Save or Undo", vbCritical, Me.Caption
'        Cancel = True
'        Exit Sub
'    End If
'
'    BitEnabled ITGLedgerMain, Me, ITGLedgerMain.tbrMain, , , , , , , , , , True
'    BitVisible ITGLedgerMain.tbrMain
'    ITGLedgerMain.tbrMain.Buttons("btnFind").ButtonMenus("btnFindP").Enabled = False
'
'
'
'
'
'    Set rsHeader = Nothing
'    Set rsC = Nothing
'    Set rsDummy = Nothing
'    Set rsDummyC = Nothing
'    Set rsHistory = Nothing
'    Set connHeader = Nothing
'    Set connC = Nothing
'
'    Set frmMaintProduct = Nothing
'
'    lCloseWindow = True
'End Sub
'
''Add new record to the recordset
'Public Sub TBNew()
'
'    BitEnabled ITGLedgerMain, Me, ITGLedgerMain.tbrMain, , , , True, True, , , True, True, , , , True
'    txtItemNo.BackColor = &HE0FFFF
'    Mode = AddNewEdit
'
'    If rsHeader.State <> adStateOpen Then
'        OpenNewConnection connHeader
'        OpenNewConnection connC
'        OpenRecordsetWithCN rsC, "*", "Supply_C", connC, "WHERE 1 = 0"
'        OpenRecordsetWithCN rsHeader, "*", "Supply", connHeader, "WHERE 1 = 0"
'        SetDataSource
'        SetDataField
'    Else
'        vBM = rsHeader.Bookmark
'    End If
'
'    rsHeader.AddNew
'    rsHeader!cCompanyID = COID
'    rsHeader!cType = "Office"
'
'    Set FrmName = Me
'    FormLocking False
'    cmdHistory.Enabled = False
'    SSTab1.Tab = 0
'    SSTab2.Tab = 0
'    txtItemNo.SetFocus
'
'End Sub
'
''Undo all changes to the recordset
'Public Sub TBUndoAll()
'On Error GoTo ErrorHandler
'
'    Mode = Normal
'
'    If rsHeader.Status = adRecNew Then TBUndoCurrent
'
'    rsHeader.CancelBatch adAffectAll
'    rsC.CancelBatch adAffectAll
'
'    UnbindControls
'
'    If rsHeader.RecordCount <> 0 Then rsHeader.Bookmark = vBM
'
'    Set FrmName = Me
'    FormLocking True
'    cmdHistory.Enabled = True
'    dtbFrom.Enabled = True
'    dtbTo.Enabled = True
'
'    If rsHeader.RecordCount <> 0 Then
'        BitEnabled ITGLedgerMain, Me, ITGLedgerMain.tbrMain, lACNew, lACEdit, lACDelete, , , , , , , True, True, , True
'    Else
'        RSZero
'        Mode = Find
'    End If
'
'    sbRS.Panels(2) = ""
'
'    SetDataSource
'    SetDataField
'
'ErrorHandler:
'    If Err.Number = -2147217885 Then
'        Resume Next
'    ElseIf Err.Number = -2147217842 Then 'Operation was cancelled. (Error returned by ITGDateBox)
'        TBUndoAll
'    End If
'
'End Sub
'
''Undo changes on the current record
'Public Sub TBUndoCurrent()
'On Error GoTo ErrorHandler
'
'    GetChild
'    If rsHeader.Status = adRecNew Then
'        rsC.CancelBatch adAffectAll
'        rsHeader.CancelUpdate
'    Else
'        rsHeader.CancelBatch adAffectCurrent
'        rsC.CancelBatch adAffectAll
'    End If
'
'    If rsHeader.RecordCount = 0 Then RSZero
'
'ErrorHandler:
'    If Err.Number = -2147217885 Then
'        Resume Next
'    ElseIf Err.Number = -2147217842 Then 'Operation was cancelled. (Error returned by ITGDateBox)
'        TBUndoCurrent
'    End If
'
'End Sub
'
''Save all changes
'Public Sub TBSave()
'Dim OKUpdate As Boolean
'On Error GoTo ErrHandler
'
'    'Audit Trail
'    lBoolean = False
'    If rsHeader.Status = adRecNew Then lBoolean = True
'
'    If Not MandatoryOK Then Exit Sub
'
'    OKUpdate = False
'    cn.BeginTrans
'    connHeader.BeginTrans
'    connC.BeginTrans
'
'    rsHeader.UpdateBatch adAffectAll
'    rsC.UpdateBatch adAffectAll
'
'    cn.CommitTrans
'    connHeader.CommitTrans
'    connC.CommitTrans
'    OKUpdate = True
'
'    Set FrmName = Me
'    FormLocking True
'    cmdHistory.Enabled = True
'    dtbFrom.Enabled = True
'    dtbTo.Enabled = True
'    BitEnabled ITGLedgerMain, Me, ITGLedgerMain.tbrMain, lACNew, lACEdit, lACDelete, , , , , , , True, True, , True
'    Mode = Normal
'
'    MsgBox "Record/s successfully saved.", vbInformation, "ComUnion"
'
'    'Audit trail
'    UpdateLogFile "Product", Trim(txtItemNo), IIf(lBoolean, "Inserted", "Updated")
'
'    lblHeader = rsHeader!cSupplyNo & " - " & rsHeader!cDesc & ""
'    lblDetails = GetValueFrTable("cDescription", "CLASSIFICATION", "cClassCode = '" & Trim(rsHeader!cPDCode) & "' AND cType = 'PD'") & ", " & _
'            "Balance: " & Format(rsHeader!nBalance, "#,##0.#0") & " " & rsHeader!cUnit & ""
'    sbRS.Panels(2) = ""
'
'ErrHandler:
'    If Err.Number = -2147217885 Then
'        Resume Next
'    ElseIf Err.Number = -2147217864 Then
'        OKUpdate = True
'        cn.RollbackTrans
'        connHeader.RollbackTrans
'        connC.RollbackTrans
'        MsgBox "Record cannot be updated. Some values may have been changed by other user/s since last read." & vbCr & _
'                "Records will be automatically refreshed. All changes made to the record will be gone upon refresh.", vbInformation, "ComUnion"
'        vBookMark = rsHeader.Bookmark
'        UnbindControls
'        rsHeader.Requery
'        rsC.Requery
'        BitEnabled ITGLedgerMain, Me, ITGLedgerMain.tbrMain, lACNew, lACEdit, lACDelete, , , , , , , True, True, , True
'        Mode = Normal
'        If rsHeader.RecordCount <> 0 Then
'            Set FrmName = Me
'            FormLocking True
'            cmdHistory.Enabled = True
'            dtbFrom.Enabled = True
'            dtbTo.Enabled = True
'            SetDataField
'            SetDataSource
'            rsHeader.Bookmark = vBookMark
'        Else
'            RSZero
'        End If
'    End If
'    If Not OKUpdate Then
'        MsgBox "Transaction update failed.", vbInformation, "ComUnion"
'        cn.RollbackTrans
'        connHeader.RollbackTrans
'        connC.RollbackTrans
'        ErrorLog Err.Number, Err.Description, Me.Name 'Error log
'    End If
'
'End Sub
'
''Sets the form & recorset to add/edit mode
'Public Sub TBEdit()
'    Mode = AddNewEdit
'    BitEnabled ITGLedgerMain, Me, ITGLedgerMain.tbrMain, , , , True, True, , , True, True, , , , True
'    Set FrmName = Me
'    FormLocking False
'    cmdHistory.Enabled = False
'    txtItemNo.Locked = True
'    SSTab2.Tab = 0
'    SSTab1.Tab = 0
'    txtDesc.SetFocus
'    vBM = rsHeader.Bookmark
'End Sub
'
''Delete record
'Public Sub TBDelete()
'On Error GoTo ErrorHandler
'
'    sID = Trim(txtItemNo)
'
'    If rsHeader.RecordCount = 0 Then Exit Sub
'
'    Dim rs As New ADODB.Recordset
'    Set rs = Nothing
'    rs.Open "SELECT A.cItemNo FROM VItem A, Item B WHERE A.cCompanyID = B.cCompanyID and A.cItemNo = '" & Trim(txtItemNo) & "' ", cn, adOpenStatic
'
'    If rs.RecordCount <> 0 Then
'        MsgBox "Unable to delete. Referenced by other transactions.", vbExclamation, "ALERT"
'        rs.Close
'        GoTo ErrorHandler
'    End If
'
'    If MsgBox("Are you sure you want to delete this record?", vbQuestion + vbYesNo, "ComUnion") = vbNo Then Exit Sub
'
'    GetChild
'    If rsC.RecordCount <> 0 Then
'        rsC.MoveFirst
'        Do Until rsC.RecordCount = 0
'            rsC.Delete adAffectCurrent
'            If rsC.RecordCount <> 0 Then rsC.MoveFirst
'        Loop
'    End If
'
'    'Audit trail
'    UpdateLogFile "Product", Trim(txtItemNo), "Deleted"
'
'    rsHeader.Delete adAffectCurrent
'    rsC.UpdateBatch adAffectAll
'    rsHeader.UpdateBatch adAffectAll
'
'    TBPrevRec
'
'    Mode = Normal
'
'    If rsHeader.RecordCount = 0 Then
'        RSZero
'    Else
'        vBookMark = rsHeader.Bookmark
'        UnbindControls
'        SetDataSource
'        SetDataField
'        rsHeader.Bookmark = vBookMark
'    End If
'
'ErrorHandler:
'    If Err.Number = -2147217885 Then
'        Resume Next
'    ElseIf Err.Number = -2147217864 Then
'        cn.Execute "DELETE Supply_C WHERE cSupplyNo = '" & sID & "' AND cCompanyID = '" & COID & "'"
'        cn.Execute "DELETE Supply WHERE cSupplyNo = '" & sID & "' AND cCompanyID = '" & COID & "'"
'        Resume Next
'    End If
'
'End Sub
'
''Search using the frmITGSearch
'Public Sub TBFind()
'    Mode = Normal
'    txtItemNo.Locked = True
'    frmITGSearch.Show
'End Sub
'
''Search using the recordset primary key
'Public Sub TBFindPrimary()
'    RSZero
'    Mode = Find
'End Sub
''Reload menu buttons (do not delete this sub)
'Public Sub TBBitReload()
'    BitVisible ITGLedgerMain.tbrMain, True
'    ITGLedgerMain.tbrMain.Buttons("btnFind").ButtonMenus("btnFindP").Enabled = True
'    BitReload ITGLedgerMain, Me, ITGLedgerMain.tbrMain, sBit
'    Set FrmName = Me
'    dtgName = dtgC.Name
'End Sub
'
''Close active window
'Public Sub TBCloseWindow()
'    Unload Me
'End Sub
'
''Move first
'Public Sub TBFirstRec()
'    If rsHeader.State <> adStateOpen Then Exit Sub
'    MoveFirst rsHeader
'End Sub
'
''Move previous
'Public Sub TBPrevRec()
'    If rsHeader.State <> adStateOpen Then Exit Sub
'    MovePrevious rsHeader
'End Sub
'
''Move next
'Public Sub TBNextRec()
'    If rsHeader.State <> adStateOpen Then Exit Sub
'    MoveNext rsHeader
'End Sub
'
''Move last
'Public Sub TBLastRec()
'    If rsHeader.State <> adStateOpen Then Exit Sub
'    MoveLast rsHeader
'End Sub
'
''Add new line to the detail recordset
'Public Sub TBNewLine()
'
'    If rsHeader!cSupplyNo = "" Then Exit Sub
'
'    If dtgName = "dtgC" Then
'        rsC.AddNew
'        rsC!cCompanyID = COID
'        rsC!cSupplyNo = Trim(txtItemNo)
'        GetChild
'        dtgC.SetFocus
'        dtgC.Col = 0
'        rsC.MoveLast
'    End If
'
'End Sub
'
''Delete line in the detail recordset
'Public Sub TBDeleteLine()
'On Error GoTo ErrorHandler
'
'    If dtgName = "dtgC" Then
'        If rsC.RecordCount = 0 Then Exit Sub
'        vBookMark = dtgC.Bookmark
'        GetChild
'        dtgC.Bookmark = vBookMark
'        rsC.Delete adAffectCurrent
'    End If
'    GetChild
'
'ErrorHandler:
'    If Err.Number = -2147217885 Then
'        Resume Next
'    End If
'
'End Sub
'
''Undo all
'Public Sub TBUndoLineAll()
'On Error GoTo ErrorHandler
'
'ErrorHandler:
'    If Err.Number = -2147217885 Then
'        Resume Next
'    End If
'End Sub
'
''Undo current line
'Public Sub TBUndoLineCurrent()
'    MsgBox "Unavailable on " & Me.Name
'End Sub
'
''Post current record
'Public Sub TBPostRecord()
'    MsgBox "Unavailable on " & Me.Name
'End Sub
'
''Cancel current record
'Public Sub TBCancelRecord()
'    MsgBox "Unavailable on " & Me.Name
'End Sub
'
''Print
'Public Sub TBPrintRecord()
'    MsgBox "Unavailable on " & Me.Name
'End Sub
'
''Sets the data source of the controls
'Sub SetDataSource()
'    Set FrmName = Me
'    BindControls rsHeader
'    Set dtgC.DataSource = rsC
'    Set dtgList.DataSource = rsHeader
'End Sub
'
''Sets the data field for every bounded controls
'Sub SetDataField()
'    With rsHeader
'        txtItemNo.DataField = !cSupplyNo
'        txtPartNo.DataField = !cPartNo
'        txtDesc.DataField = !cDesc
'        txtType.DataField = !cType
'        txtUnit.DataField = !cUnit
'        txtWH.DataField = !cWH
'        txtDept.DataField = !cDepartment
'        txtSRP.DataField = !nSRPrice
'        txtPQty.DataField = !cPQty
'        txtPCost.DataField = !nPCost
'        txtSUnit.DataField = !cSUnit
'        txtSQty.DataField = !cSQty
'        txtSCost.DataField = !nSMCost
'        txtSSRP.DataField = !nSSRP
'        txtMinimum.DataField = !nMinimum
'        txtMaximum.DataField = !nMaximum
'        txtReorder.DataField = !nReorderQty
'        txtReorderPt.DataField = !nReorderPt
'        txtLeadTime.DataField = !nLeadTime
'    End With
'End Sub
'
'
'Private Sub rsHeader_MoveComplete(ByVal adReason As ADODB.EventReasonEnum, ByVal pError As ADODB.Error, adStatus As ADODB.EventStatusEnum, ByVal pRecordset As ADODB.Recordset)
'On Error GoTo ErrorHandler
'
'    If Not (rsHeader.EOF) Or Not (rsHeader.BOF) Then
'        lblHeader = rsHeader!cSupplyNo & " - " & rsHeader!cDesc & ""
'        lblDetails = GetValueFrTable("cDescription", "CLASSIFICATION", "cClassCode = '" & Trim(rsHeader!cPDCode) & "' AND cType = 'PD'") & ", " & _
'                    "Balance: " & Format(rsHeader!nBalance, "#,##0.#0") & " " & rsHeader!cUnit & ""
'        sbRS.Panels(1) = "Record: " & IIf((rsHeader.AbsolutePosition = -2), "0", rsHeader.AbsolutePosition) & "/" & rsHeader.RecordCount
'
'        If rsHeader.Status <> adRecNew Then
'            txtItemNo.Locked = True
'        Else
'            txtItemNo.Locked = False
'        End If
'
'        If Mode = AddNewEdit Then
'            Select Case rsHeader.Status
'                Case adRecNew
'                    sbRS.Panels(2) = "New"
'                Case adRecModified
'                    sbRS.Panels(2) = "Modified"
'                Case Else
'                    sbRS.Panels(2) = ""
'            End Select
'        Else
'            sbRS.Panels(2) = ""
'        End If
'
'        GetChild
'        ShowProductBalance
'
'    Else
'        lblHeader = "Product ID - Description"
'        lblDetails = "Product Division, Balance"
'        sbRS.Panels(1) = "Record: 0/0"
'        sbRS.Panels(2) = ""
'        txtItemNo.Locked = False
'    End If
'
'    If Mode = AddNewEdit Then
'        'dtgWH.Refresh
'        'dtgSub.Refresh
'        dtgC.Refresh
'    End If
'
'    Set dtgHistory.DataSource = Nothing
'    dtgHistory.Refresh
'    dtbFrom.Text = "__/__/____"
'    dtbTo.Text = "__/__/____"
'
'    'lvwList.ListItems.Clear
'
'ErrorHandler:
'    'Err.Number -2147217885
'    'Description - Row handle referred to a deleted row or a row marked for deletion.
'    If Err.Number = -2147217885 Then
'        Resume Next
'    End If
'
'End Sub
'
'Private Sub Timer1_Timer()
'    If Mode = AddNewEdit Then
'        SSTab2.TabEnabled(1) = False
'        'cmdWHBalance.Enabled = False
'    Else
'        SSTab2.TabEnabled(1) = True
'        'cmdWHBalance.Enabled = True
'    End If
'
'    If Mode <> Find Then Exit Sub
'    If txtItemNo.BackColor = &HE0FFFF Then
'        txtItemNo.BackColor = &HE0E0E0
'        Exit Sub
'    End If
'    If txtItemNo.BackColor <> &HE0FFFF Then
'        txtItemNo.BackColor = &HE0FFFF
'        Exit Sub
'    End If
'End Sub
'
'Private Sub txtItemNo_KeyDown(KeyCode As Integer, Shift As Integer)
'    If KeyCode = 13 Then
'        'Find
'        If Mode = Find Then
'
'            FormWaitShow App.Path & "\Transmit.avi", "Loading data . . ."
'
'            OpenNewConnection connHeader
'            OpenNewConnection connC
'
'            Set rsHeader = Nothing
'            Set rsC = Nothing
'            Set rsHeader = New ADODB.Recordset
'            Set rsC = New ADODB.Recordset
'
'            If Trim(txtItemNo) = "" Then
'                OpenRecordsetWithCN rsC, "*", "Supply_C", connC
'                OpenRecordsetWithCN rsHeader, "*", "Supply", connHeader
'            Else
'                OpenRecordsetWithCN rsC, "*", "Supply_C", connC, "WHERE cSupplyNo LIKE '" & Trim(txtItemNo) & "%'"
'                OpenRecordsetWithCN rsHeader, "*", "Supply", connHeader, "WHERE cSupplyNo LIKE '" & Trim(txtItemNo) & "%'"
'            End If
'
'            Set FrmName = Me
'            FormLocking True
'            cmdHistory.Enabled = True
'            dtbFrom.Enabled = True
'            dtbTo.Enabled = True
'
'            If rsHeader.RecordCount = 0 Then
'                FormWaitHide
'                MsgBox "No matching record/s found.", vbInformation, "ComUnion Search"
'                rsHeader.Close
'                rsC.Close
'                BitEnabled ITGLedgerMain, Me, ITGLedgerMain.tbrMain, lACNew, , , , , , , , , True, , , True
'                txtItemNo.Locked = False
'                txtItemNo.SetFocus
'                Exit Sub
'            End If
'
'            SetDataSource
'            SetDataField
'
'            txtItemNo.BackColor = &HE0FFFF
'            Mode = Normal
'
'            BitEnabled ITGLedgerMain, Me, ITGLedgerMain.tbrMain, lACNew, lACEdit, lACDelete, , , , , , , True, True, , True
'
'            FormWaitHide
'        End If
'    End If
'End Sub
'
'Private Sub txtItemNo_LostFocus()
'    'Does Code Already exists
'    If Mode = AddNewEdit Then
'        If Trim(txtItemNo) = "" Then
'            MsgBox "Empty primary input.", vbInformation, "ComUnion"
'            txtItemNo.SetFocus
'        Else
'            If rsHeader.Status <> adRecNew Then Exit Sub
'            txtItemNo = Trim(txtItemNo)
'            If IDExisting(rsHeader, "cSupplyNo", "Supply", Trim(rsHeader!cSupplyNo)) Then
'                MsgBox "Product ID already exists.", vbInformation, "ComUnion"
'                txtItemNo.SetFocus
'            Else
'                txtPartNo = Trim(txtItemNo)
'            End If
'        End If
'    End If
'End Sub
'
'Private Sub txtType_Change()
'    If Trim(txtType) <> "" Or txtType <> vbNullString Then
'        cboType = Trim(txtType)
'    Else
'        cboType.ListIndex = -1
'    End If
'End Sub
'
''Check if all mandatory fields are complete
'Function MandatoryOK() As Boolean
'
'    MandatoryOK = True
'
'    If Trim(txtItemNo) = "" Then
'        MandatoryOK = False
'        MsgBox "Field 'Product ID' is mandatory. Null value is not allowed.", vbInformation, "ComUnion"
'        txtItemNo.SetFocus
'        Exit Function
'    End If
'
'    If rsHeader.Status = adRecNew Then
'        If IDExisting(rsHeader, "cSupplyNo", "Supply", Trim(rsHeader!cSupplyNo)) Then
'            MandatoryOK = False
'            MsgBox "Supply ID already exists.", vbInformation, "ComUnion"
'            txtItemNo.SetFocus
'            Exit Function
'        End If
'    End If
'
'    'For part number & product type control (cannot save product with existing Part No. & Product Type)
'    cString = Trim(GetValueFrTable("cSupplyNo", "Supply", "cPartNo = '" & Trim(txtPartNo) & "' AND cType = '" & Trim(txtType) & "'"))
'    If cString <> "" Then
'        If cString <> Trim(txtItemNo) Then
'            MandatoryOK = False
'            MsgBox "Cannot save product with existing Part No. & Product Type.", vbInformation, "ComUnion"
'            cboType.SetFocus
'            Exit Function
'        End If
'    End If
'
'    If Trim(txtDesc) = "" Then
'        MandatoryOK = False
'        MsgBox "Field 'Product Description' is mandatory. Null value is not allowed", vbInformation, "ComUnion"
'        txtDesc.SetFocus
'        Exit Function
'    ElseIf Trim(txtUnit) = "" Then
'        MandatoryOK = False
'        MsgBox "Field 'Unit' is mandatory. Null value is not allowed", vbInformation, "ComUnion"
'        txtUnit.SetFocus
'        Exit Function
'    ElseIf Trim(txtWH) = "" Then
'        MandatoryOK = False
'        MsgBox "Field 'Warehouse' is mandatory. Null value is not allowed", vbInformation, "ComUnion"
'        txtWH.SetFocus
'        Exit Function
'    ElseIf Trim(txtType) = "" Then
'        MandatoryOK = False
'        MsgBox "Field 'Type' is mandatory. Null value is not allowed", vbInformation, "ComUnion"
'        cboType.SetFocus
'        Exit Function
'    ElseIf CDbl(txtSRP) = 0 Then
'        MandatoryOK = False
'        MsgBox "Field 'SRP' is mandatory. Null or zero value is not allowed", vbInformation, "ComUnion"
'        txtSRP.SetFocus
'        Exit Function
'    End If
'
'    GetChild
'
'    If rsC.RecordCount <> 0 Then rsC.MoveFirst
'    Do Until rsC.EOF
'        If rsC.Status = (adRecNew) Or rsC.Status = (adRecModified) Then
'            If IsNull(rsC!cCompItemNo) Then
'                rsC.Delete
'            ElseIf Trim(rsC!cCompItemNo) = "" Then
'                rsC.Delete
'            Else
'                rsC.MoveNext
'            End If
'        Else
'            rsC.MoveNext
'        End If
'    Loop
'
'    GetChild
'
'End Function
'
''Filter detail recordset to header's primary
'Private Sub GetChild()
'    rsC.Filter = "cItemNo = '" & Trim(rsHeader!cSupplyNo) & "'"
'End Sub
'
''Sets the form if record number is zero
'Private Sub RSZero()
'    lblHeader = "Product ID - Description"
'    lblDetails = "Product Division, Balance"
'    sbRS.Panels(1) = "Record: 0/0"
'    sbRS.Panels(2) = ""
'
'    Set dtgC.DataSource = Nothing
'    dtgC.Refresh
'
'    Set FrmName = Me
'    UnbindControls
'    TextClearing
'    FormLocking True
'
'    Set dtgHistory.DataSource = Nothing
'    dtgHistory.Refresh
'    dtbFrom.Text = "__/__/____"
'    dtbTo.Text = "__/__/____"
'
'    If rsHeader.State = adStateOpen Then rsHeader.Close
'    If rsC.State = adStateOpen Then rsC.Close
'
'    BitEnabled ITGLedgerMain, Me, ITGLedgerMain.tbrMain, lACNew, , , , , , , , , True, , , True
'
'    txtItemNo.Locked = False
'    txtItemNo.SetFocus
'
'    Mode = Find
'End Sub
'
'Private Sub txtWH_LostFocus()
'    If Mode <> AddNewEdit Then Exit Sub
'    If Trim(txtWH) = "" Then Exit Sub
'    If GetValueFrTable("cWH", "WHSE", "cWH = '" & Trim(txtWH) & "'") = "" Then cmdPickWH_Click
'End Sub
'
''Dummy recordset for component items (ITEM_C)
'Private Sub DummyCRS(rsFrom As ADODB.Recordset)
'Dim strPD As String
'
'    Set rsDummyC = New Recordset
'    Set rs = New Recordset
'
'    With rsDummyC.Fields
'        .Append "cSupplyNo", adBSTR, , adFldIsNullable
'        .Append "cCompItemNo", adBSTR, , adFldIsNullable
'        .Append "cCompItemDesc", adBSTR, , adFldIsNullable
'        .Append "nQty", adDouble, , adFldIsNullable
'        .Append "PD", adBSTR, , adFldIsNullable
'        .Append "SRP", adDouble, , adFldIsNullable
'        .Append "WSP", adDouble, , adFldIsNullable
'    End With
'
'    rsDummyC.Open
'
'    Set rs = rsFrom.Clone
'
'    Set rs = Nothing
'
'    Set dtgC.DataSource = Nothing
'    Set dtgC.DataSource = rsC
'
'End Sub
'
''Pass dummy recordset values to the real recordset
'Private Sub DummyToReal()
'
'    rsC.Filter = "cSupplyNo = '" & Trim(rsHeader!cSupplyNo) & "'"
'    rsDummyC.Filter = "cSupplyNo = '" & Trim(rsHeader!cSupplyNo) & "'"
'
'    If rsC.RecordCount <> 0 Then
'        rsC.MoveFirst
'        Do Until rsC.RecordCount = 0
'            rsC.Delete adAffectCurrent
'            If rsC.RecordCount <> 0 Then rsC.MoveFirst
'        Loop
'    End If
'    rsC.Filter = "cSupplyNo = '" & Trim(rsHeader!cSupplyNo) & "'"
'
'    Do While Not rsDummyC.EOF
'        rsC.AddNew
'        rsC!cCompanyID = COID
'        rsC!cSupplyNo = Trim(rsDummyC!cSupplyNo) & ""
'        rsC!cCompItemNo = Trim(rsDummyC!cCompItemNo) & ""
'        rsC!cCompItemDesc = Trim(rsDummyC!cCompItemDesc) & ""
'        rsC!nQty = CDbl(rsDummyC!nQty)
'        rsDummyC.MoveNext
'    Loop
'
'End Sub
'
''Get item values from item table
'Private Sub GetItemValues(oRS As Recordset, dtg As DataGrid, strItemNo As String)
'
'    If dtg.Name = "dtgC" Then
'        oRS!cCompItemDesc = Trim(GetValueFrTable("cDesc", "Supply", "cSupplyNo = '" & Trim(strItemNo) & "'")) & ""
'    End If
'    cString = Trim(GetValueFrTable("cPDCode", "Supply", "cSupplyNo = '" & Trim(strItemNo) & "'")) & ""
'    dtg.Columns(2).Value = Trim(GetValueFrTable("cDescription", "CLASSIFICATION", "cClassCode = '" & Trim(cString) & "' AND cType = 'PD'")) & ""
'
'    If dtg.Name = "dtgC" Then
'        dtg.Columns(4).Value = Trim(GetValueFrTable("nSRPrice", "Supply", "cSupplyNo = '" & Trim(strItemNo) & "'")) & ""
'        dtg.Columns(5).Value = Trim(GetValueFrTable("nWSPrice", "Supply", "cSupplyNo = '" & Trim(strItemNo) & "'")) & ""
'    End If
'
'End Sub
'
''Show the balances per product code
''Binding of the textboxex was disabled
'Private Sub ShowProductBalance()
'Dim rsBalance As New Recordset
'
'    If Mode = AddNewEdit Then Exit Sub
'
''    sSQL = "SELECT *, ISNULL((nInitial - nOutgoing + nIncoming + nRetSales - nRetPur - nIssues + nBack - nProdOut + nProdIn + nAdjustment - nSampleDemo), 0) AS nBalance " & _
''            "FROM V_ProductBalanceInquiry_Module WHERE cItemNo = '" & rsHeader!cItemNo & "' AND cCompanyID = '" & COID & "'"
''    rsBalance.Open sSQL, cn, adOpenForwardOnly, adLockReadOnly
'
'    ProductBalanceCommand rsBalance, rsHeader!cSupplyNo
'
'    txtInitial = 0
'    'txtSales = 0
'    txtPurchase = 0
'    'txtProdFG = 0
'    'txtProdRM = 0
'    'txtSampleDemo = 0
'    txtIssues = 0
'    'txtBackOrder = 0
'    txtAdjustment = 0
'    'txtReserved = 0
'    txtBalance = 0
'
'    If rsBalance.RecordCount <> 0 Then
'        txtInitial = rsBalance!nInitial
'        'txtSales = rsBalance!nOutgoing - rsBalance!nRetSales
'        txtPurchase = rsBalance!nIncoming - rsBalance!nRetPur
'        'txtProdFG = rsBalance!nProdIn
'        'txtProdRM = rsBalance!nProdOut
'        'txtSampleDemo = rsBalance!nSampleDemo
'        txtIssues = rsBalance!nIssues
'        'txtBackOrder = rsBalance!nBack
'        txtAdjustment = rsBalance!nAdjustment
'        'txtReserved = rsBalance!nReserved
'        txtBalance = rsBalance!nBalance
'    End If
'
'
'    Set rsBalance = Nothing
'
'End Sub
'
'
